package com.example.design.c.state.demo3;

import lombok.Getter;
import lombok.Setter;

/**
 * 线程状态抽象类
 */
@Setter
@Getter
public abstract class ThreadAbstractState {
    /**
     * 状态名称
     */
    private String stateName;

    public boolean getCPU(ThreadContext context) {
        return false;
    }

    public boolean resume(ThreadContext context) {
        return false;
    }

    public boolean start(ThreadContext context) {
        return false;
    }

    public boolean stop(ThreadContext context) {
        return false;
    }

    // suspend 暂停 悬挂 吊起
    public boolean suspend(ThreadContext context) {
        return false;
    }
}
